package com.pro.service.imple;

import com.pro.dao.CourseMapper;
import com.pro.entity.Course;
import com.pro.entity.CourseClass;
import com.pro.entity.CourseRecord;
import com.pro.service.CourseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/*
    赵自强
    2021/11/4
    课程serviceImple
*/
@Service
public class CourseServiceImple implements CourseService {

    @Autowired
    private CourseMapper courseDao;

    @Override
    public List<CourseClass> getCourseClass() {
        return courseDao.getCourseClass();
    }

    @Override
    public List<Course> getCourse(Integer classId) {
        return courseDao.getCourse(classId);
    }

    @Override
    public List<Course> advancedRetrieval(Integer classId, String courseName, Double coursePrice, String trueName, Integer courseCstatus, String courseLabel) {
        return courseDao.advancedRetrieval(classId,courseName,coursePrice,trueName,courseCstatus,courseLabel);
    }

    @Override
    public List<Course> ordinarySearch(String name,String courseName,String trueName,String courseLabel) {
        return courseDao.ordinarySearch(name,courseName,trueName,courseLabel);
    }

    @Override
    public Course getCourseById(Integer courseId) {
        return courseDao.getCourseById(courseId);
    }

    @Override
    public Boolean courseEdit(Course course) {
        return courseDao.courseEdit(course);
    }

    @Override
    public List<Course> getCourseJournals() {
        return courseDao.getCourseJournals();
    }

    @Override
    public Boolean addCourseJournal(Course course) {
        return courseDao.addCourseJournal(course);
    }

    @Override
    public List<CourseRecord> getAuditDetalis(Integer courseId,Integer type) {
        return courseDao.getAuditDetalis(courseId,type);
    }

    @Override
    public Boolean delCourse(Integer courseId) {
        return courseDao.delCourse(courseId);
    }

    @Override
    public Boolean addCourse(Course course) {
        return courseDao.addCourse(course);
    }

    @Override
    public List<Course> operationLog() {
        return courseDao.operationLog();
    }

    @Override
    public Boolean addoperationLog(Course course) {
        return courseDao.addoperationLog(course);
    }

    @Override
    public Boolean addZtreeNode(CourseClass courseClass) {
        return courseDao.addZtreeNode(courseClass);
    }

    @Override
    public Boolean editZtreeNode(CourseClass courseClass) {
        return courseDao.editZtreeNode(courseClass);
    }

    @Override
    public Boolean delZtreeNode(CourseClass courseClass) {
        return courseDao.delZtreeNode(courseClass);
    }

    @Override
    public List<Course> operationLogRetrieval(Integer dictSort, String trueName) {
        return courseDao.operationLogRetrieval(dictSort,trueName);
    }

    @Override
    public List<Course> journalRetrieval(String courseName, String name, String trueName, Integer courseCstatus) {
        return courseDao.journalRetrieval(courseName,name,trueName,courseCstatus);
    }

    @Override
    public Boolean addExcel(Course course) {
        return courseDao.addExcel(course);
    }

    @Override
    public Boolean setCourseStatus(Integer courseStatus,Integer courseId) {
        return courseDao.setCourseStatus(courseStatus,courseId);
    }
}
